import { Command } from '@/commands/command.ts'
import { new_command } from '@/models/command.ts'

export class Md5Command extends Command {
    public static new(args: string): Command {
        const command = new_command()
        command.args = args
        command.name = 'md5'
        command.component = 'AllowCopyCommandComponent'

        return new Md5Command(command, false)
    }

    usage(): string {
        return 'md5 [-u] 字符串'
    }

    description(): string {
        return `<div>对给定的文本进行MD5加密</div>
        <br/>
        <div>选项说明:</div>
        <br/>
        <div class="option-row"><span class="option-option">-u --upper</span><span>结果大写</span></div>`
    }
}
